<div class="blog-page">
	<div class="row">
			<div>
				<div class="note note-success note-bordered" style="background-color:#ffffff;border-left: 5px solid #3E97E4;">
					<p style="font-size: 17px; font-weight: bold; color: #3E97E4;">
						 {{bid.bidTitle}}
					</p>
					<div class="col-md-6" style="text-align: right;margin-top: -50px;margin-left: 53%;">
							<div class="btn-group btn-theme-panel">
								<a href="javascript:;" class="btn dropdown-toggle"  ng-click="bidForm.callBack();">
								<i class="icon-arrow-left" style="font-size: 45px;"></i>
								</a>
							</div>
						</div>
				</div>
				<div style="background-color:#ffffff;height:250px;">
				 <form action="#" class="form-horizontal form-row-seperated w5c-form" w5c-form-validate novalidate name="biddingDepositForm">
						<table style="width:100%;height:100%;margin-left:10px;color:#8C7B7B;">
							<tr style="border: 1px solid #F9F2F2; ">
								<td>
									<div ng-if="bid.status==1">
										<button type="button" class="btn btn-success title-action" style="background-color: #d23030;border-color: #d23030;" tabindex="0">
										 正在进行...
										</button>
									</div>
									<div ng-if="bid.status==2">
										<button type="button" class="btn dark" tabindex="0">
										 竞价结束
										</button>
									</div>
								</td>
								<td> 
									<div ng-if="bid.status==1">
										<span>距离结束仅剩：
										<font style=" color: #A56322;font-size: 20px;">{{bid.limitTimeDay}}</font> 天
										<font style=" color: #A56322;font-size: 20px;">{{bid.limitTimeHour}}</font> 时
										<font style=" color: #A56322;font-size: 20px;">{{bid.limitTimeMinute}}</font> 分
										<font style=" color: #A56322;font-size: 20px;">{{bid.limitTimeSecond}}</font>秒 
										</span>
									</div>
								</td>
							</tr>
							<tr>
								
								<td ng-if="bidRecordArray.length>0 && bid.status==1"><span>当前价 ：<font style=" color: #d23030;font-size: 30px;font-weight:bold;">{{topRecord.bidPrice | currency : '￥'}}</font>  出价<font style=" color: #A56322;font-size: 20px;">{{bidRecordArray.length}}</font>次</span></td>
								<td ng-if="bidRecordArray.length<=0 && bid.status==1"><span>当前价 ：<font style=" color: #d23030;font-size: 30px;font-weight:bold;">{{bid.basePrice | currency : '￥'}}</font></span>  暂无出价</td>
								
								<td ng-if="bidRecordArray.length>0 && bid.status==2"><span>成交价 ：<font style=" color: #d23030;font-size: 30px;font-weight:bold;">{{topRecord.bidPrice | currency : '￥'}}</font>  出价<font style=" color: #A56322;font-size: 20px;">{{bidRecordArray.length}}</font>次</span></td>
								<td ng-if="bidRecordArray.length<=0 && bid.status==2"><span>成交价 ：<font style=" color: #d23030;font-size: 30px;font-weight:bold;">{{bid.basePrice | currency : '￥'}}</font>  出价<font style=" color: #A56322;font-size: 20px;">{{bidRecordArray.length}}</font>次</span></td>
								
								<td ng-if="flag && bid.status==1">
									<table>
										<tr>
										<td>
											<span >出&nbsp;价&nbsp;&nbsp;</span>
										</td>
										<td>
											<a href="javascript:;" class="btn btn-icon-only gray" style="border-radius:0px !important;background-color: #7DC1FB;height:34px;color:#fff;" ng-click="bidForm.minusPrice();">
												<i class="fa fa-minus"></i>
											</a>
										</td>
										<td>
											<div>
												<input type="text" placeholder="出价金额" class="form-control"  ng-model="payPrice" ed-validate="double" disabled/>
											</div>
										</td>
										<td>
											<a href="javascript:;" class="btn btn-icon-only gray" style="border-radius:0px !important;background-color: #7DC1FB;height:34px;color:#fff;" ng-click="bidForm.addPrice();">
												<i class="fa fa-plus"></i>
											</a>
										</td>
										</tr>
									</table>
								</td>
							</tr>
							<tr>
								<td>保 证 金： <font style=" color: #A56322;font-size: 30px;font-weight:bold;">{{bid.deposit | currency : '￥'}} </font>不成拍则结束后退还</td>
								<td>
										<div ng-if="flag && bid.status==1">
											<button  type="button" class="btn btn-success title-action" style="width:180px;background-color: #3E97E4;border-color: #3E97E4;"
											ng-click="bidForm.offerPrice();" tabindex="0">
											<i class="fa fa-legal"></i><font style="font-weight:bold;">&nbsp;&nbsp;&nbsp;出价</font>
											</button>
											</div>
										<div ng-if="!flag && !hasPayingOrder && bid.status==1">
											<button  type="button"  class="btn btn-success title-action" style="background-color: #d23030;border-color: #d23030;"
											ng-click="bidForm.payDeposit();"
											tabindex="0">
											<i class="fa fa-legal"></i> <font style="font-weight:bold;">交保证金报名</font>
											</button>
										</div>
										<div ng-if="!flag && hasPayingOrder && bid.status==1">
											<button type="button" class="btn btn-success title-action" style="background-color: #d23030;border-color: #d23030;"
											tabindex="0">
											<i class="glyphicon glyphicon-time"></i>  <font style="font-weight:bold;">支付中...</font>
											</button>
										</div>
									</td>
							</tr>
							<tr style="height: 30px;">
							<td>
							参与资格： 本次拍卖仅支持注册及以上级别会员参与
							</td>
							</tr>
							<tr style="height:30px;border: 1px solid #F9F2F2;border-bottom:none;">
								<td>
								 起拍价 : <font style="color:#A56322;">{{bid.basePrice | currency : '￥'}}</font>
								</td>
								<td>
									加价幅度 : <font style="color:#A56322;">{{bid.increasePrice | currency : '￥'}}</font>
								</td>
							</tr>
							<tr style="height:30px;">
								<td>
								延时周期 : 5分钟/次
								</td>
								<td>
									拍卖方式 : 升价拍
								</td>
							</tr>
						</table>
					</form>
				</div>
				<hr>
				<div style="background-color:#ffffff;height:35px;">
					<table style="width:100%;height:100%;color:#8C7B7B;font-size:18px;border-left: 5px solid #3E97E4;">
					<tr>
					<td style="text-align:center;"><font> 竞拍流程 : </font></td>
					<td style="text-align:center;"><font> 01 交保证金</font></td>
					<td style="text-align:center;"><font><li class="fa fa-angle-right" style="font-size: 20px;color:#3E97E4;margin-right:20px;"></li> 02 参与竞拍</font></td>
					<td style="text-align:center;"><font><li class="fa fa-angle-right" style="font-size: 20px;color:#3E97E4;margin-right:20px;"></li> 03  竞拍成功</font></td>
					<td style="text-align:center;"><font><li class="fa fa-angle-right" style="font-size: 20px;color:#3E97E4;margin-right:20px;"></li> 04 支付货款</font></td>
					<td style="text-align:center;"><font><li class="fa fa-angle-right" style="font-size: 20px;color:#3E97E4;margin-right:20px;"></li> 05 交易完成</font></td>
					</tr>
					</table>
				</div>
				<hr>
				<div class="tabbable-custom">
					<tabset> 
						<tab heading="竞价资源">
								<div class="tab-content">
									<div class="tab-pane active">
										<div class="form" style="overflow: auto;">
											<div class="portlet light" ng-repeat="media in mediaTypes">
												<div class="portlet-title" style="background-color:#ffffff">
													<div class="caption" ng-if="media.parentId == '1'">
														<i class="fa fa-cogs font-green-sharp"></i>
														<span class="caption-subject font-green-sharp bold uppercase">{{media.mediaName}}</span>
													</div>
													<div class="caption" ng-if="media.parentId == '2'">
														<i class="fa fa-cogs font-red-sunglo"></i>
														<span class="caption-subject font-red-sunglo bold uppercase">{{media.mediaName}}</span>
													</div>
												</div>
												<div class="portlet-body" ng-if="media.parentId == '1'">
													<div class="table-responsive">
														<table class="table">
														<thead>
														<tr >
															<th>
																 #
															</th>
															<th>
																 线路
															</th>
															<th>
																 车牌
															</th>
															<th>
																 资源名称
															</th>
															<th>
																 资源价格(¥)
															</th>
															<th>
																 开始日期
															</th>
															<th>
																结束日期
															</th>
														</tr>
														</thead>
														<tbody>
														<tr ng-repeat="resource in media.resources">
															<td>
																 {{$index + 1}}
															</td>
															<td>
																{{resource.lineNo}}
															</td>
															<td>
																{{resource.plateNo}}
															</td>
															<td>
																{{resource.resourceName}}
															</td>
															<td>
																{{resource.resourcePrice | currency : '￥'}}
															</td>
															<td>
																{{resource.startDate}}
															</td>
															<td>
																 {{resource.endDate}}
															</td>
														</tr>
														</tbody>
														</table>
													</div>
												</div>
												<div class="portlet-body" ng-if="media.parentId == '2'">
													<div class="table-responsive">
														<table class="table">
														<thead>
														<tr>
															<th>
																 #
															</th>
															<th>
																站点名称
															</th>
															<th>
																 道路名称
															</th>
															<th>
																 资源名称
															</th>
															<th>
																 资源价格(¥)
															</th>
															<th>
																开始日期
															</th>
															<th>
																截止日期
															</th>
														</tr>
														</thead>
														<tbody>
														<tr ng-repeat="resource in media.resources">
															<td>
																 {{$index + 1}}
															</td>
															<td>
																{{resource.stopName}}
															</td>
															<td>
																{{resource.roadName}}
															</td>
															<td>
																{{resource.resourceName}}
															</td>
															<td>
																{{resource.resourcePrice | currency : '￥'}}
															</td>
															<td>
																{{resource.startDate}}
															</td>
															<td>
																 {{resource.endDate}}
															</td>
														</tr>
														</tbody>
														</table>
													</div>
												</div>
											</div>
										</div>
									</div>
								</div>
						 </tab>
						 <tab heading="出价记录({{bidRecordArray.length}})">
								<div class="tab-content">
									<div class="tab-pane active">
										<div class="form" style="overflow: auto;">
											<div class="portlet light" style="background-color:#ffffff">
												<div class="portlet-body">
													<div class="table-responsive">
														<table class="table" style="color:#666;">
														<thead style="background-color: #F7F2F2;">
														<tr>
															<th>
																 状态
															</th>
															<th>
																 价格(¥)
															</th>
															<th>
																 竞拍单位
															</th>
															<th>
																时间
															</th>
														</tr>
														</thead>
														<tbody>
														<tr ng-repeat="bidRecord in bidRecordArray">
															<td ng-if="$first">
																<font style="color:red">领先</font>
															</td>
															<td ng-if="!$first">
																出局
															</td>
															<td ng-if="$first">
																<font style="color:red">{{bidRecord.bidPrice | currency : '￥'}}</font>
															</td>
															<td ng-if="!$first">
																{{bidRecord.bidPrice | currency : '￥'}}
															</td>
															<td>
																{{bidRecord.customerName}}
															</td>
															<td>
																{{bidRecord.biddingTime}}
															</td>
														</tr>
														</tbody>
														</table>
													</div>
												</div>
											</div>
										</div>
									</div>
								</div>
							</tab> 
							<tab heading="竞价须知">
								<div class="tab-content">
									<div class="tab-pane active">
									&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{{bid.bidNotice}}
									</div>
								</div>
							</tab> 
					</tabset>
		</div>
	</div>
	</div>
</div>
